/* ###################################################################
**  Copyright 2022 GSST, Inc.


**  Filename  : GSStm32F401_Isr.h
**  Project     : TXBJ
**  Processor : STM32F401RCT6
**  Author     : GSST
**  Version    : V1.0
**  Compiler  : IAR C Compiler
**  Date/Time : 2022
**
** ###################################################################*/

#ifndef __GSStm32F401_Interrupts_H_
#define __GSStm32F401_Interrupts_H_

/*******************************************************************************
 * Header
 ******************************************************************************/
 
#include "GSStm32F4_Common.h" 

/*******************************************************************************
 * Definitions
 ******************************************************************************/

#define SYS_START_DELAY 1000u // unit: ms

/*******************************************************************************
 * Variables
 ******************************************************************************/
extern uint16 g_initFinishFlag; 
extern uint16 g_sysStartFlag;


extern uint8 g_systickH8;


typedef struct{
    uint32_t        d_tim5Cnt;
    uint32_t        d_timMSCnt;
    uint32_t        d_tim5SentCnt;

    uint32_t        d_tim5CntTemp;
    uint8_t         d_isFirstUp;

    uint8_t         testId;
    int16_t         testPos;
    uint32_t        testNum;
    uint16_t   ChickHareToStart;
    // uint16_t    ChickHareToClean;
    uint16_t        d_currentBuff[2000];
    uint16_t         d_posBuff[2000];

    uint16_t        d_currentBuff1[2000];
    uint16_t      d_posBuff1[2000];

    uint16_t      d_currentBuff2[2000];
    uint16_t      d_posBuff2[2000];

    uint16_t      d_currentBuff3[2000];
    uint16_t      d_posBuff3[2000];

    uint16_t      d_currentBuff4[2000];
    uint16_t      d_posBuff4[2000];
    //float32_t   d_currentBuff[400];
   // float32_t   d_posBuff[400];
   // float32_t   testBuff4[400];

    uint8_t ChickHareToChoiceMotor;
    uint16_t    cyt821cnt;
    uint32_t   cyt625cnt;
    uint8_t     readCnt;
    uint8_t      l_temp[28];
    uint32_t   cyt1020cnt;
}_ISR_DATA;
extern _ISR_DATA    g_isrData;
/*******************************************************************************
 * API
 ******************************************************************************/


#endif
